home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / xpcom / nsIProperty.h < prev    next >
C/C++ Source or Header  |  2006-05-08  |  3KB  |  110 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsIProperty.idl
  3.  */
  4.  
  5. #ifndef __gen_nsIProperty_h__
  6. #define __gen_nsIProperty_h__
  7.  
  8.  
  9. #ifndef __gen_nsISupports_h__
  10. #include "nsISupports.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17. class nsIVariant; /* forward declaration */
  18.  
  19.  
  20. /* starting interface:    nsIProperty */
  21. #define NS_IPROPERTY_IID_STR "6dcf9030-a49f-11d5-910d-0010a4e73d9a"
  22.  
  23. #define NS_IPROPERTY_IID \
  24.   {0x6dcf9030, 0xa49f, 0x11d5, \
  25.     { 0x91, 0x0d, 0x00, 0x10, 0xa4, 0xe7, 0x3d, 0x9a }}
  26.  
  27. class NS_NO_VTABLE nsIProperty : public nsISupports {
  28.  public: 
  29.  
  30.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_IPROPERTY_IID)
  31.  
  32.   /**
  33.      * Get the name of the property.
  34.      */
  35.   /* readonly attribute AString name; */
  36.   NS_IMETHOD GetName(nsAString & aName) = 0;
  37.  
  38.   /**
  39.      * Get the value of the property.
  40.      */
  41.   /* readonly attribute nsIVariant value; */
  42.   NS_IMETHOD GetValue(nsIVariant * *aValue) = 0;
  43.  
  44. };
  45.  
  46. /* Use this macro when declaring classes that implement this interface. */
  47. #define NS_DECL_NSIPROPERTY \
  48.   NS_IMETHOD GetName(nsAString & aName); \
  49.   NS_IMETHOD GetValue(nsIVariant * *aValue); 
  50.  
  51. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  52. #define NS_FORWARD_NSIPROPERTY(_to) \
  53.   NS_IMETHOD GetName(nsAString & aName) { return _to GetName(aName); } \
  54.   NS_IMETHOD GetValue(nsIVariant * *aValue) { return _to GetValue(aValue); } 
  55.  
  56. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  57. #define NS_FORWARD_SAFE_NSIPROPERTY(_to) \
  58.   NS_IMETHOD GetName(nsAString & aName) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetName(aName); } \
  59.   NS_IMETHOD GetValue(nsIVariant * *aValue) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetValue(aValue); } 
  60.  
  61. #if 0
  62. /* Use the code below as a template for the implementation class for this interface. */
  63.  
  64. /* Header file */
  65. class nsProperty : public nsIProperty
  66. {
  67. public:
  68.   NS_DECL_ISUPPORTS
  69.   NS_DECL_NSIPROPERTY
  70.  
  71.   nsProperty();
  72.  
  73. private:
  74.   ~nsProperty();
  75.  
  76. protected:
  77.   /* additional members */
  78. };
  79.  
  80. /* Implementation file */
  81. NS_IMPL_ISUPPORTS1(nsProperty, nsIProperty)
  82.  
  83. nsProperty::nsProperty()
  84. {
  85.   /* member initializers and constructor code */
  86. }
  87.  
  88. nsProperty::~nsProperty()
  89. {
  90.   /* destructor code */
  91. }
  92.  
  93. /* readonly attribute AString name; */
  94. NS_IMETHODIMP nsProperty::GetName(nsAString & aName)
  95. {
  96.     return NS_ERROR_NOT_IMPLEMENTED;
  97. }
  98.  
  99. /* readonly attribute nsIVariant value; */
  100. NS_IMETHODIMP nsProperty::GetValue(nsIVariant * *aValue)
  101. {
  102.     return NS_ERROR_NOT_IMPLEMENTED;
  103. }
  104.  
  105. /* End of implementation class template. */
  106. #endif
  107.  
  108.  
  109. #endif /* __gen_nsIProperty_h__ */
  110.